Skip to content

fix(id): fill rotation: None in ChainExt test helpers - #7300

Merged
dezren39 merged 1 commit into
mainfrom
fix/id-chainext-rotation-tests
Nov 8, 2026
Merged

dezren39 merged 1 commit into
mainfrom
fix/id-chainext-rotation-tests

Conversation

@dezren39

@dezren39 dezren39 commented Nov 8, 2026 •

Copy link
Copy Markdown
Member

What broke

The id crate test build fails on current main with E0063, which blocks the amd NixOS switch (the id-0.1.0 derivation builds the tests):

  • pkgs/id/src/event_store/sync.rs:1265 — missing field rotation in initializer of chain::ChainExt
  • pkgs/id/src/log_sync.rs:968 — same

Both sites are the test-local ext() helper in the #2414 range-session tally tests (test_a_range_session_counts_a_stored_but_unapplied_arrival_as_voided, mirrored in both modules).

Cause

#5526 added pub rotation: Option<IssuerRotation> to ChainExt and updated the production initializers (and some test initializers — the frozen-arrivals test in the same file has it), but missed these two helpers.

Fix

Add rotation: None to both helpers. The helpers only build group.op / message events, and the field is defined as the rotation record of an issuer.rotation event and None for every other kind, so this preserves test intent exactly. Two lines, no lib change.

Verification

  • cargo check --tests in pkgs/id: exit 0 (previously exit 101 with the two E0063 errors above).
  • cargo test --lib filtered to the affected tests: 3 passed, 0 failed:
    • event_store::sync::tests::test_a_range_session_counts_a_stored_but_unapplied_arrival_as_voided
    • log_sync::tests::test_a_range_session_counts_a_stored_but_unapplied_arrival_as_voided
    • event_store::sync::tests::test_a_range_session_counts_frozen_arrivals_as_refused

Unblocks the amd switch carrying the opencode pin bump from #7103.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

The issuer-rotation change (#5526) added a rotation field to ChainExt and updated the production initializers, but missed the test-local ext() helpers in the #2414 range-session tally tests. Both helpers build group.op/message events, for which rotation is None by definition, so the field addition is intent-preserving. The omission fails the crate test build with E0063 and blocks the amd NixOS switch.
@dezren39
dezren39 requested a review from a team as a code owner November 8, 2026 05:16
@dezren39
dezren39 merged commit f7679c9 into main Nov 8, 2026
5 of 7 checks passed
@coderabbitai

coderabbitai Bot commented Nov 8, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 6 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 2744089c-77c8-40ba-8dfb-ecd696c74d27
Commits

Reviewing files that changed from the base of the PR and between c990026 and c85646e.

Files selected for processing: 2

  • pkgs/id/src/event_store/sync.rs
  • pkgs/id/src/log_sync.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@dezren39
dezren39 deleted the fix/id-chainext-rotation-tests branch November 8, 2026 05:16
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-08T05:17:11.575467Z c85646e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant